<?php
/**
 * Created by JetBrains PhpStorm.
 * User: Grom Hellscream
 * Date: 11/16/12
 * Time: 3:58 PM
 * To change this template use File | Settings | File Templates.
 */
// No direct access to this file
defined('_JEXEC') or die('Restricted access');
$document = JFactory::getDocument();
$document->addStyleDeclaration('a.readon {
	background: none repeat scroll 0 0 #F89A20;
	color: #FFFFFF;
	float: right;
	padding: 0 5px;
}
a.readon:hover {
	background: none repeat scroll 0 0 #F89A20;
	color: #FFFFFF;
	float: right;
	padding: 0 5px;
	text-decoration: none;
}
ul {
    list-style: none;
}
ul li {
    display: inline;
}
');

$canbos = $this->get('canbos');
$pagination = $this->get('pagination');
$khoi = $this->get('khoi');
$donvi = $this->get('donvi');
?>
<div id="crumbs">
    <div style="color: #222222;font-weight: normal;margin: 0;padding: 0">
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=vast') ?>">Trang chủ</a> »
        <span>Cơ cấu tổ chức</span> »
        <a href="<?php echo JRoute::_('index.php?option=com_vast&view=donvitructhuoc&id=' . $khoi->id); ?>"><?php echo $khoi->ten ?></a> »        
        <span><?php echo $donvi->ten; ?></span>        
    </div>
</div>

<div id="main" class="home">
    <h3 class="title green">Danh sách cán bộ thuộc <?php echo $donvi->ten; ?></h3>
    <div class="single">    
    <?php
    if (count($canbos) > 0)
        foreach ($canbos as $canbo)
        {
            ?>
            <div>
                <table>
                    <tr>
                        <td style="padding-top: 5px; padding-right: 5px; padding-bottom: 5px; padding-left: 5px;">
                            <img style="width: 180px; height: 125px;" src="<?php echo $canbo->anhdaidien; ?>" alt="<?php echo $canbo->hoten; ?>"/>
                        </td>
                        <td width="100%" valign="top" style="padding: 5px;">
                            <a href="index.php?option=com_vast&view=chitietcanbo&id=<?php echo $canbo->id; ?>">
                                <?php echo $canbo->hoten; ?>
                            </a>
                            <br/>
                            Điện thoại: <?php echo $canbo->dienthoai; ?>
                            <br/>
                            Nguyên quán: <?php echo $canbo->nguyenquan; ?>
                            <br/>
                            Địa chỉ hiện tại: <?php echo $canbo->diachihientai; ?>
                            <br/>
                            Thư điện tử: <?php echo $canbo->thudientu; ?>
                            <br/>
                            Dân tộc: <?php echo $canbo->dantoc; ?>
                            <a class="readon" href="index.php?option=com_vast&view=chitietcanbo&id=<?php echo $canbo->id; ?>">Đọc thêm ...</a>
                        </td>
                    </tr>
                </table>
                <hr style="height: 0px; border-top-color: #00ccff; border-right-color: #00ccff; border-bottom-color: #00ccff; border-left-color: #00ccff; border-top-width: 1px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px; border-top-style: dashed; border-right-style: dashed; border-bottom-style: dashed; border-left-style: dashed;"/>
            </div>
            <?php
        }
    ?>
    </div>
    <div id="tnt_pagination">
        <?php echo $pagination->getPagesLinks(); ?>
    </div>
</div>